package cn.ss.exam2302.entity;

import com.baomidou.mybatisplus.annotation.*;
import lombok.AllArgsConstructor;
import lombok.Data;
import lombok.NoArgsConstructor;

import java.util.Date;

@Data
@AllArgsConstructor
@NoArgsConstructor
@TableName("t_user")
public class User {
    @TableId(value= "usr_id", type = IdType.AUTO)
    private Integer usrId;
    private String usrName;
    private String usrAccount;
    private String usrPassword;
    private String usrSalt;
    private String usrRole;
    @TableField(updateStrategy = FieldStrategy.IGNORED)
    private Boolean usrDelete;
    private Date usrCreatedate;
    private Date usrUpdatedate;

    public User(String usrName, String usrAccount, String usrPassword, String usrSalt, String usrRole, Boolean usrDelete, Date usrCreatedate, Date usrUpdatedate) {
        this.usrName = usrName;
        this.usrAccount = usrAccount;
        this.usrPassword = usrPassword;
        this.usrSalt = usrSalt;
        this.usrRole = usrRole;
        this.usrDelete = usrDelete;
        this.usrCreatedate = usrCreatedate;
        this.usrUpdatedate = usrUpdatedate;
    }
}
